package entity;

import cn.hutool.core.util.StrUtil;

/**
 * @Description:
 * @author: knight
 * @Date: 2018/9/9 22:05
 */
public class TDYFileInfo {


    public static final String SOA_PARENT_PATH = "D:\\gitProject\\tdy-nht\\tdy-nht-soa-parent\\";

    public static final String SERVICE_PATH = SOA_PARENT_PATH + "tdy-nht-service\\src\\main\\java\\com\\tdy\\nht\\doc\\";

    public static final String API_PATH = SOA_PARENT_PATH + "tdy-nht-api\\src\\main\\java\\com\\tdy\\nht\\doc\\";


    public static final String WEB_PARENT_PATH = "D:\\gitProject\\tdy-nht\\tdy-nht-web-parent\\";
    public static final String WEB_CONTROLLER_PATH = WEB_PARENT_PATH + "tdy-nht-web-operate\\src\\main\\java\\com\\tdy\\nht\\web\\operate\\controller\\";


    public static final String WEB_PAGE_PATH = WEB_PARENT_PATH+"tdy-nht-web-operate\\src\\main\\resources\\templates\\";



    public static final String WEB_JS_PATH = WEB_PARENT_PATH+"tdy-nht-web-operate\\src\\main\\resources\\static\\scripts\\nht\\";


    private String filePath;

    private String fileName;
    private String modelName;
    /**
     * 注释
     */
    private String annotation;
    /**
     * 作者
     */
    private String author;

    /**
     * 只有在创建controller时才有值
     */
    private String pageName;

    /**
     * 是否生产保存和编辑方法 1表示生成
     */
    private String saveMethod;


    public TDYFileInfo(String filePath, String fileName, String modelName) {
        this.filePath = filePath;
        this.fileName = fileName;
        this.modelName = modelName;
    }

    public String getFilePath() {
        return filePath;
    }

    public void setFilePath(String filePath) {
        this.filePath = filePath;
    }

    public String getFileName() {
        return fileName;
    }

    public void setFileName(String fileName) {
        this.fileName = fileName;
    }

    public String getModelName() {
        return modelName;
    }

    public void setModelName(String modelName) {
        this.modelName = modelName;
    }

    public String getAnnotation() {
        return annotation;
    }

    public void setAnnotation(String annotation) {
        this.annotation = annotation;
    }

    public String getAuthor() {
        if (StrUtil.isBlank(author)) {
            return "yinqi";
        }
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    public String getPageName() {
        return pageName;
    }

    public void setPageName(String pageName) {
        this.pageName = pageName;
    }

    public String getSaveMethod() {
        return saveMethod;
    }

    public void setSaveMethod(String saveMethod) {
        this.saveMethod = saveMethod;
    }
}
